package main

import (
	"ams_client/plugin/sub"
	"fmt"
	"github.com/urfave/cli/v2"
	"lib/structs/ams"
	"os"
	"time"
)

const macpVersion = "1.0.0"

func main() {
	app := &cli.App{
		Name:    ams.Macp,
		Version: fmt.Sprintf("%s build:%s", macpVersion, time.Now().Format("20060102_15:04:05")),
		Usage:   "miao ams client plugin (macp),详见子命令",
	}
	app.Commands = []*cli.Command{
		sub.HandsUpCommand(),
		sub.IdpPlugin.IdpCommand(),
	}
	if err := app.Run(os.Args); err != nil {
		fmt.Printf("命令行调用错误：%s ，请查看帮助文档", err.Error())
	}
}
